Data

Import data

In this document we are going to calculate Evasion from the Vaisala Sensors and compare them to the eosFD flux measurements as well as see how they relate to other variables such as precipitation and temperature. First we import the data and for now we will filter so we are looking at non-injections

Create new time variables for ease of plotting

These new variables will help us plot each seperate day on a timescale of midnight -> midnight

df$day <- as.factor(substr(as.character(df$DateTime),1,10))
times <- substr(as.character(df$DateTime),12,16)
df$time <- strftime(df$DateTime, format="%H:%M")
df$time <- as.POSIXct(df$time, format="%H:%M")

todayStart <- as.POSIXct(paste0(Sys.Date(),"00:00:00"))
todayEnd <- as.POSIXct(paste0(Sys.Date(),"23:59:59"))

CO2 Change

Change in CO2

The first step in calculating flux from the stream is to calculate change in CO2 concentrations between two points within the stream. We will look at two pairs of sensors (1->3 & 3->4). Once we determine change in CO2 concentration, we will convert ppm to uMols and then account for stream metabolism (respiration and photosynthesis) to calculate flux. First, let’s visualize change in CO2 accross the pairs of sensors

So now that we know what the change in CO2 between stations, it’s time to account for stream metabolism. Stream metabolism includes Ecosystem Respiration (ER) and Gross Primary Production / phtosynthesis (GPP). Both of these processes include a 1:1 exchange of CO2 and DO molecules. Photosynthesis: Use CO2 and create O2 (1:1 ratio).

Respiration: Use O2, create CO2 (1:1 ratio).

Respiration can occur in the abscence of sunlight while photosynthesis cannot. At night, stream processes are respiration driven. During the day both respiration and photosynthesis occur. We can look at the changes in DO over the similar stretches of stream and time period. We did not have a DO sensor at station 3 but we did have one at station 2.

Dissolved Oxygen

Change in Dissolved Oxygen

Mass Conversion

Convert CO2 from concentration to mass

Now that we know the change in CO2 in terms of concentration (ppm), we can convert it to mass. Specifically, we will take this opportunity to convert to micromoles (uMols), which we will eventually use to express evasion.

# Distances are 17,30,80

filt13$uMols_13 <- ((filt13$V1-filt13$V3)/ 37.6) *.0018*(1000000/44.01)*filt13$stn1_Q/1000 

filt34$uMols_34 <- ((filt34$V3-filt34$V4)/ 64) *.0018*(1000000/44.01)*filt34$stn3_Q/1000

Plotting data

Histograms of change in CO2

CO2 Change over time

Change in CO2 (umols)

Evasion Using Daily Stream Metabolism

Using the USGS streammetabolizer package, daily estimates of GPP and ER can be calculated at each of the DO sensor locations. This is done in a seperate script located in: ‘Ecuador/Analysis/Stream_Metabolism/metabolism.R’. The results are used to estimate daily evasion for the reach. The values expressed in the results of the streammetabolizer tool are grams of O2 / m^2 /d^-1. We need to convert this into uMols and then multiply by -1 to determine uMols CO2.

Estimate daily ER and GPP in uMols of CO2

1 mole of CO2 = 31.9988 grams.

Average ER and GPP Values for Stations 1 & 2

We average the GPP and ER values at station 1 & 2 for use with change in CO2 between station 1 and 3. We use GPP and ER estimates from station 4 for the change in CO2 between stations 3 and 4.

stn12 <- metabCO2%>%
  filter(Station < 4)%>%
  group_by(DateTime)%>%
  mutate(GPP_CO2uMol12 = mean(GPP_CO2uMol),
         ER_CO2uMol12 = mean(ER_CO2uMol))%>%
  ungroup()

stn4 <- metabCO2%>%
  filter(Station == 4)%>%
  mutate(GPP_CO2uMol34 = GPP_CO2uMol,
         ER_CO2uMol34 = ER_CO2uMol)

metabCO2avg <- left_join(stn12,stn4, by="date")

Evasion Calculations

Convert CO2 Change into Daily Values

DCO2Daily13 <- filt13%>%
  group_by(day)%>%
  mutate(DailyChange13 = mean(uMols_13*86400))%>%
  select(day,DailyChange13)%>%
  distinct()%>%
  rename("date"="day")

DCO2Daily <- filt34%>%
  group_by(day)%>%
  mutate(DailyChange34 = mean(uMols_34*86400))%>%
  select(day,DailyChange34)%>%
  distinct()%>%
  rename("date"="day")%>%
  left_join(DCO2Daily13, by="date")

Merge ‘Daily Change’ with stream metabolism to get metabolism adjusted evasion

##

Daily Evasion & Metabolism in µmols

Compare with eosFD numbers

Synoptic points show ~ 19g per day of CO2 / 1 uMol